package com.yulongtian.offers.day202209.day20220923;

import java.util.Arrays;

/**
 * https://leetcode.cn/problems/zui-xiao-de-kge-shu-lcof/
 * @author YulongTian
 * @date 2022/9/23 - 17:01
 */
public class Test06 {
    public static void main(String[] args) {

    }

    public static int[] getLeastNumbers(int[] arr, int k) {

        Arrays.sort(arr);

        int[] res=new int[k];
        for(int i=0;i<k;i++){
            res[i]=arr[i];
        }
        return res;
    }

}
